package com.exam.service.teacher;

import java.io.Serializable;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.exam.common.vo.ExamTeacherVO;
import com.exam.common.vo.page.PageModel;
import com.exam.dao.teacher.TeacherDao;
import com.exam.entity.ExamTeacher;

@Service
@Transactional
public class TeacherServiceImp implements TeacherService{

	@Autowired
	TeacherDao teaDao;
	
	@Override
	public Serializable save(ExamTeacher entity) {
		return teaDao.save(entity);
	}

	@Override
	public Serializable merge(ExamTeacher entity) {
		return teaDao.merge(entity);
	}

	@Override
	public void update(ExamTeacher entity) {
		teaDao.update(entity);
	}

	@Override
	public void saveOrUpdate(ExamTeacher entity) {
		teaDao.saveOrUpdate(entity);
	}

	@Override
	public void delete(ExamTeacher entity) {
		teaDao.delete(entity);
	}

	@Override
	public ExamTeacher findByKey(Serializable id) {
		return teaDao.findByKey(id);
	}

	@Override
	public List<ExamTeacher> findAll() {
		return teaDao.findAll();
	}

	@Override
	public PageModel<ExamTeacherVO> findByPage() {
		return teaDao.findByPage();
	}

	@Override
	public ExamTeacherVO findByTeaNumber(Integer teaNumber) {
		return teaDao.findByNumber(teaNumber);
	}

	@Override
	public PageModel<ExamTeacherVO> findBySearcherTip(String searcherTip) {
		return teaDao.findBySearcherTip(searcherTip);
	}

}
